package org.example.swagger2.controller;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author 季舟
 * @Date 2025-02-05 13:41
 */
@RestController
@RequestMapping("/user")
@Api(tags = "用户管理")
public class UserController {
    @ApiOperation("获取用户信息")
    @GetMapping("/getUser")
    public String getUser(@ApiParam(required = true, value = "用户id") @RequestParam(value = "id",defaultValue = "1") Integer id) {
        return "user id:"+ id;
    }
}
